:root {
    --primary-color: #3498db;
    --secondary-color: #2c3e50;
    --accent-color: #e74c3c;
    --light-bg: #f8f9fa;
    --dark-bg: #343a40;
    --sidebar-width: 250px;
}
.user-info {
            padding: 15px;
            border-top: 1px solid rgba(255, 255, 255, 0.1);
            margin-top: auto;
        }
        .user-info .username {
            color: #fff;
            font-size: 14px;
            margin-bottom: 10px;
        }
        .logout-btn {
            background: rgba(255, 255, 255, 0.1);
            border: none;
            color: #fff;
            padding: 8px 15px;
            border-radius: 4px;
            cursor: pointer;
            width: 100%;
            transition: all 0.3s ease;
        }
        .logout-btn:hover {
            background: rgba(255, 255, 255, 0.2);
        }
        .sidebar {
            width: var(--sidebar-width);
            background: linear-gradient(180deg, #2c3e50 0%, #1a2a3a 100%);
            height: 100vh;
            position: fixed;
            left: 0;
            top: 0;
            box-shadow: 4px 0 15px rgba(0, 0, 0, 0.2);
            z-index: 1000;
            padding: 0;
            display: flex;
            flex-direction: column;
        }
        .nav-menu {
            list-style: none;
            padding: 20px 0;
            margin: 0;
            flex: 1;
        }
        .nav-item.logout {
            margin-top: auto;
            border-top: 1px solid rgba(255, 255, 255, 0.1);
            padding: 15px;
        }
        .nav-item.logout a {
            color: #fff;
            text-decoration: none;
            display: block;
            padding: 8px 15px;
            background: rgba(255, 255, 255, 0.1);
            border-radius: 4px;
            transition: all 0.3s ease;
        }
        .nav-item.logout a:hover {
            background: rgba(255, 255, 255, 0.2);
        }
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    background: linear-gradient(135deg, #1a2a6c, #b21f1f, #1a2a6c);
    color: #333;
    min-height: 100vh;
    padding-top: 20px;
    display: flex;
    margin: 0;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.sidebar-title {
    font-size: 1.2em;
    font-weight: bold;
    color: #fff;
    text-align: center;
}

.user-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.username {
    color: #4CAF50;
    font-weight: 500;
    font-size: 0.9em;
}

.logout {
    color: #ff6b6b;
    text-decoration: none;
    font-size: 0.9em;
    padding: 5px 10px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.logout:hover {
    background: rgba(255, 107, 107, 0.1);
}

.logout-btn {
    color: #e74c3c;
    text-decoration: none;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.logout-btn:hover {
    background-color: #e74c3c;
    color: white;
}

.nav-item {
    padding: 15px 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 12px;
    color: rgba(255, 255, 255, 0.7);
    position: relative;
    margin: 5px 0;
}

.nav-item::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 4px;
    background: #3498db;
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    padding-left: 30px;
}

.nav-item:hover::before {
    transform: scaleY(1);
}

.nav-item.active {
    background: rgba(52, 152, 219, 0.2);
    color: #fff;
    padding-left: 30px;
}

.nav-item.active::before {
    transform: scaleY(1);
}

.nav-item::after {
    content: "•";
    font-size: 1.2rem;
    color: #3498db;
    opacity: 0;
    transition: all 0.3s ease;
}

.nav-item:hover::after,
.nav-item.active::after {
    opacity: 1;
}

/* 调整主内容区域 */
.main-content {
    margin-left: var(--sidebar-width);
    flex: 1;
    padding: 20px;
    min-height: 100vh;
    background: linear-gradient(135deg, #1a2a6c, #b21f1f, #1a2a6c);
}

.main-container {
    width: 100%;
    margin: 0;
    padding: 20px;
}

.content-wrapper {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

/* 视频区域 */
.video-section {
    min-height: 1000px;
    flex: 3;
    display: flex;
    flex-direction: row;
    gap: 20px;
    justify-content: center;
    align-items: flex-start;
}

.video-container {
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    width: 45%;
    border: 3px solid var(--primary-color);
    padding: 3px;
    background-color: white;
    transition: all 0.3s ease;
}

.video-container:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
}

.video-container img,
.video-container video {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px;
}

/* 右侧内容区域 */
.content-section {
    flex: 1.2;
    display: flex;
    flex-direction: column;
    min-width: 350px;
    max-height: 900px;
    overflow-y: auto;
}

h1 {
    color: var(--secondary-color);
    font-weight: 700;
    margin-bottom: 30px;
    text-align: center;
    font-size: 2.2em;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

/* 调整面板样式 */
.panel {
    display: none;
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.panel.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

.panel-header {
    padding: 15px 20px;
    background: rgba(255, 255, 255, 0.9);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.panel-title {
    font-weight: 600;
    font-size: 1.3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--secondary-color);
}

.badge {
    background: linear-gradient(135deg, var(--primary-color) 0%, #2980b9 100%);
    color: white;
    font-weight: 500;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.2);
}

.gesture-display {
    padding: 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.gesture-display:hover {
    background-color: rgba(52, 152, 219, 0.02);
}

.gesture-display:last-child {
    border-bottom: none;
}

.gesture-label {
    font-size: 1rem;
    color: #6c757d;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.gesture-label i {
    color: var(--primary-color);
    font-size: 1.1em;
}

.gesture-value {
    font-size: 1.5rem;
    font-weight: 500;
    padding: 12px 15px;
    border-radius: 10px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.gesture-value.empty {
    color: #6c757d;
    background-color: #f8f9fa;
    font-style: italic;
}

.gesture-value.active {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1) 0%, rgba(41, 128, 185, 0.1) 100%);
    color: var(--primary-color);
    border-left: 4px solid var(--primary-color);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.1);
}

.gesture-value.pulse {
    animation: pulse 1.5s infinite;
    will-change: transform;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.02); }
    100% { transform: scale(1); }
}

.all-contents {
    padding: 20px;
}

.gesture-item {
    padding: 20px;
    margin-bottom: 15px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.9);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.gesture-item:last-child {
    margin-bottom: 0;
}

.gesture-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.gesture-item.active {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1) 0%, rgba(41, 128, 185, 0.1) 100%);
    border-left: 4px solid var(--primary-color);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.1);
}

.gesture-item-title {
    font-weight: 600;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.gesture-item-content {
    padding: 10px 0;
    color: var(--secondary-color);
    font-size: 1.1em;
}

.gesture-item-content.empty {
    color: #6c757d;
    font-style: italic;
}

/* 面板切换按钮 */
.panel-tabs {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.tab-btn {
    flex: 1;
    padding: 12px;
    border: none;
    background: rgba(255, 255, 255, 0.9);
    color: var(--secondary-color);
    border-radius: 10px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.tab-btn i {
    font-size: 1.1em;
}

.tab-btn:hover {
    background: rgba(52, 152, 219, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.tab-btn.active {
    background: linear-gradient(135deg, var(--primary-color) 0%, #2980b9 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.2);
}

/* 响应式布局调整 */
@media (max-width: 1200px) {
    .content-wrapper {
        flex-direction: column;
    }
    .video-section {
        flex-direction: column;
        width: 100%;
    }
    .video-container {
        width: 100%;
    }
}

@media (max-width: 768px) {
    h1 {
        font-size: 1.8rem;
        margin-bottom: 20px;
    }

    .panel-header {
        padding: 12px 15px;
    }

    .gesture-display {
        padding: 15px;
    }

    .gesture-value {
        font-size: 1.3rem;
        padding: 10px;
    }

    .tab-btn {
        padding: 10px;
        font-size: 0.9em;
    }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 登录和注册页面样式 */
body.signin {
    background: linear-gradient(135deg, #721c24 0%, #2a5298 100%);
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.signinpanel {
    width: 900px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 10px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    padding: 40px;
    transition: all 0.3s ease;
}

.signinpanel:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.signin-info {
    padding: 30px;
    color: #2c3e50;
}

.signin-info h2 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 30px;
    color: #1e3c72;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.signin-info ul {
    list-style: none;
    padding: 0;
    margin: 30px 0;
}

.signin-info ul li {
    font-size: 18px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.signin-info ul li:hover {
    transform: translateX(10px);
    color: #1e3c72;
}

.signin-info ul li i {
    color: #1e3c72;
    margin-right: 10px;
    font-size: 20px;
    transition: all 0.3s ease;
}

.signin-info ul li:hover i {
    transform: scale(1.2);
}

.register-link {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 20px;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s ease;
    font-weight: 600;
}

.register-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(30, 60, 114, 0.3);
    color: white;
    text-decoration: none;
}

.form-control {
    height: 45px;
    border-radius: 5px;
    border: 2px solid #e0e0e0;
    padding: 10px 15px;
    font-size: 16px;
    transition: all 0.3s ease;
    width: 100%;
    margin-bottom: 15px;
    background-color: rgba(255, 255, 255, 0.9);
}

.form-control:focus {
    border-color: #1e3c72;
    box-shadow: 0 0 0 0.2rem rgba(30, 60, 114, 0.25);
    background-color: white;
}

.btn-success {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    border: none;
    height: 45px;
    font-size: 18px;
    font-weight: 600;
    border-radius: 5px;
    transition: all 0.3s ease;
    width: 100%;
    color: white;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(30, 60, 114, 0.3);
    background: linear-gradient(135deg, #2a5298 0%, #1e3c72 100%);
}

.checkbox-custom {
    margin: 20px 0;
}

.checkbox-custom label {
    color: #666;
    font-size: 15px;
}

.signup-footer {
    text-align: center;
    margin-top: 30px;
    color: #666;
}

.signup-footer a {
    color: #1e3c72;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.signup-footer a:hover {
    color: #2a5298;
    text-decoration: underline;
}

.alert {
    padding: 15px;
    margin-bottom: 20px;
    border: 1px solid transparent;
    border-radius: 4px;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.alert-danger {
    color: #721c24;
    background-color: #f8d7da;
    border-color: #f5c6cb;
}

@media screen and (max-width: 768px) {
    .signinpanel {
        width: 90%;
        padding: 20px;
    }
    .signin-info {
        display: none;
    }
}

/* 统计框样式 */
.stats-section {
    margin-top: 20px;
    padding: 0 20px;
}

.stats-container {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 15px;
}

.stats-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    color: #2c3e50;
    font-size: 1.1em;
    font-weight: 500;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.stats-header i {
    color: #3498db;
}

.stats-content {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 15px;
}

.stats-item {
    text-align: center;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.stats-item:hover {
    background: #e9ecef;
    transform: translateY(-2px);
}

.stats-label {
    color: #7f8c8d;
    font-size: 0.9em;
    margin-bottom: 5px;
    display: block;
}

.stats-value {
    color: #2c3e50;
    font-size: 1.4em;
    font-weight: 600;
    display: block;
    margin: 5px 0;
}

.stats-unit {
    color: #95a5a6;
    font-size: 0.8em;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .stats-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .stats-content {
        grid-template-columns: 1fr;
    }
}
